#ifndef _MemoryPool_H_
#define _MemoryPool_H_

#include <stack>

template<class T>
class MemoryPool
{
public:
	static const uint32 DEFAULT_SIZE = 1024;

public:
	MemoryPool();
	~MemoryPool();

	bool CreatePool(uint32 size);

	T *Alloc();
	void Free(T* value);	

private:
	std::stack<T*> m_kStack;
	T *m_pkValue;
};

#include "MemoryPool.hpp"

#endif // _MemoryPool_H_
